package com.gyk.orderss.controller;

import com.gyk.orderss.pojo.TbOrder;
import com.gyk.orderss.service.impl.TbOrderServiceImpl;
import com.lwy.common.Result;
import com.lwy.common.StatusCode;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

//订单Controller
@RestController
@RequestMapping("order")
public class TbOrderController {

    @Resource
    TbOrderServiceImpl tbOrderService;

    //订单查询
    @RequestMapping("list")
    public Result<List<TbOrder>> list(){
        List<TbOrder> list = tbOrderService.list();
        return new Result<List<TbOrder>>(true, StatusCode.OK,"订单查询",list);
    }

    //分页
}
